package compiler.parse;

public class Parse {

  public compiler.errormsg.ErrorMsg errorMsg;
  public compiler.absyn.Exp absyn;

  public Parse(String filename) {
      errorMsg = new compiler.errormsg.ErrorMsg(filename);{
      	java.io.InputStream inp;
        try {
        	inp=new java.io.FileInputStream(filename);
       } catch (java.io.FileNotFoundException e) {
       	throw new Error("File not found: " + filename);
       }
       parser parser = new parser(new Yylex(inp,errorMsg), errorMsg);
      /* open input files, etc. here */

      try {
          parser./*debug_*/parse();
      } catch (Throwable e) {
      	e.printStackTrace();
      	throw new Error(e.toString());
      } 
      finally {
         try {inp.close();} catch (java.io.IOException e) {}
      }
      absyn=parser.parseResult;
    } 
  }   
}

